<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>

</head>
<body>
    <div id="one">hello</div>
    <script>
        // 弹框  阻塞代码执行
        alert(1);
        // 选中one节点设置样式
        var one=document.getElementById('one');
        console.log(one);
        one.style.backgroundColor='red';
        // 控制内部内容、文本
        /* one.innerHTML='world';
        one.innerHTML='<span>tom</span>';
        one.innerText='123';
        one.innerText='<span>tom</span>'; */

        one.innerHTML=`<table>
        <tr>
            <td>123</td>
            <td></td>
            <td></td>
            <td></td>
        </tr>
        <tr>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
        </tr>
        <tr>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
        </tr>
    </table>`
    </script>
    
</body>
</html>